---@class Battle.BuffEffect10013001:Battle.BuffEffectBase
---伤害分担
local BuffEffect10013001 = Battle.CreateClass("BuffEffect10013001",Battle.BuffEffectBase)
Battle.BuffEffect10013001 = BuffEffect10013001
function BuffEffect10013001:OnCreate(buff)
    ---@type Battle.Buffer
    self.buff = buff
    ---@type Battle.Entity
    self.actor = Battle.ActorManager.GetActor(self.buff.targetId);
    local param = decodeJsonStrToTable(buff.cfg.f_EffectParameter);
    self.percentage = param[1][1];

end

---buff生效时
function BuffEffect10013001:OnBuffStart(...)
    local param = { ... };

    local damageData = param[2]
    local damage = damageData.damage * (self.percentage/10000);--百分比回血
    self.actor:LossHp(damage,self.actor);
end

return BuffEffect10013001